<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>酒店辅助订购系统</title>
    <script th:src="@{/js/jquery-3.4.1.min.js}"></script>
</head>
<body>
<table>
    <thead>
    <tr>
        <th>名字</th>
        <th>id</th>
        <th>地址</th>
    </tr>
    </thead>
    <tbody >
    <tr th:each="hotel : ${hotels}">
        <form method="post" action="/hotel/detail">
        <td th:text="${hotel.hotelName}">Red chair</td>
        <td th:text="${hotel.hotelId}">￥350</td>
        <td th:text="${hotel.address}">2018-02-20</td>
            <td>  <a th:href= "'detail/'+ ${hotel.hotelId}">查看</a>
            </td>

        </form>
    </tr>
    </tbody>
</table>
<script>
    $(document).ready(function(){
        $("tr").click(function(){
            $(this).hide();
        });
    });
</script>

</body>
</html>